Skip to content

Fix GitHub workflow test commands - #8

Closed
samxu01 wants to merge 1 commit into
mainfrom
codex/run-npm-test-on-both-backend-and-frontend
Closed

samxu01 wants to merge 1 commit into
mainfrom
codex/run-npm-test-on-both-backend-and-frontend

Conversation

@samxu01

@samxu01 samxu01 commented May 28, 2025

Copy link
Copy Markdown
Contributor

Summary

  • unify test commands to use npm test style
  • run backend tests with --coverage
  • ensure workflow files have newline at EOF
  • revert accidental changes to backend dependencies

Testing

  • npm test in backend
  • CI=true npm test -- --watchAll=false in frontend

@samxu01 samxu01 closed this May 28, 2025
@samxu01
samxu01 deleted the codex/run-npm-test-on-both-backend-and-frontend branch February 2, 2026 04:35
samxu01 added a commit that referenced this pull request May 4, 2026
v3 had Part 4 scoped to "inspector Skills tab only" with agent
install/fork pushed entirely out of scope. That left the user-asked
v2 marketplace page and Agents tab undesigned.

v4 expands Part 4 into four sections:

  4a. Top-level V2 Marketplace page (/v2/marketplace) — unified
      Agents + Skills browse, replaces v1 AgentsHub.tsx (4954 lines)
      and SkillsCatalogPage.tsx (2061 lines) over time. Wires on top
      of existing /api/marketplace/* (PR #215+#230) and /api/skills/*.

  4b. Inspector Skills tab — per-pod contextual install. Shows which
      agents have which skills.

  4c. Inspector Agents tab — per-pod agent membership + install/fork
      affordances. Per-installed-agent: Talk to / Configure / Fork.
      Per-browse-agent: Install / Fork.

  4d. Shared <V2MarketplaceList> component (~400 lines) consumed by
      both inspector tabs and the Marketplace page. Future apps and
      widgets ports cleanly onto the same component.

Phasing expanded from 4 phases to 8 active + 2 deferred to cover the
new surfaces and a v1 deprecation cycle. Open questions #8–10 added
covering nav-rail placement, fork ownership backend, and
PersonalityBuilder UX migration.

This ADR now also lands the active "Marketplace frontend" track from
ADR-011 alongside the file-production work — they're the same surface.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
samxu01 added a commit that referenced this pull request May 4, 2026
…end state

v3 and v4 made two assumptions that turned out to be wrong:

1. Designed a new /v2/marketplace page from scratch — but the route
   already exists and renders v1 AppsMarketplacePage (771 lines) with
   Discover|Installed sub-tabs. /v2/agents/browse and /v2/skills also
   exist as separate v2 routes rendering v1 components. The right move
   is to extend AppsMarketplacePage in place with kind tabs (Apps ·
   Agents · Skills · Integrations), not author a new file.

2. Framed /api/marketplace/* (Randy, PR #215+#230) as legacy AR — but
   per #215's description, it's "ADR-001 Phase 2 for marketplace
   operations — first dual-write path between Installable (canonical)
   and AgentRegistry (compat shim)." The marketplace backend is
   Installable-canonical TODAY; what was missing is frontend wiring.

v5 corrections:

- Part 4a rewritten: extend existing AppsMarketplacePage with kind
  tabs, wire each tab to the right backend (Agents → Installable,
  Skills → AR for now, Apps/Integrations unchanged). Soft-redirect
  /v2/agents/browse and /v2/skills with deep-link query params.

- Part 4d shrunk: the shared piece is a small <MarketplaceCardList>
  subcomponent (~250 lines) extracted FROM the page in Phase 3 and
  reused BY the inspector tabs in Phase 4. v4's heavyweight
  <V2MarketplaceList> was over-engineering.

- Phasing collapsed from 8 active to 5 active. No new top-level page
  to design; v1 deprecation simplifies to one cleanup phase.

- §"Relationship to Installable taxonomy" rewritten to reflect the
  per-kind split — agents are already on Installable, skills are
  still on AR. ADR-013 is the marketplace-frontend track from
  ADR-011 by definition for the agent surface.

- Open question #7 (accelerate Phase 3?) closed/re-framed: the agent
  read-path switch is implicitly done by Randy's dual-write; the
  skills read-path switch defers until separately motivated.

- Open question #8 (nav-rail placement) closed: page already mounted.

- Open question #9 (fork ownership) narrowed: Randy's
  /api/marketplace/mine likely covers it; just verify response shape.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
samxu01 added a commit that referenced this pull request May 4, 2026
…ll surfaces (Marketplace + inspector tabs) (#287)

* docs(adr): ADR-013 agent file production — extension tool, dev skill bundles, v2 install UI

Decision spans four coordinated changes:

1. `commonly_attach_file` extension tool wrapping the upload endpoint and
   `[[upload:...]]` directive — protocol glue, not a skill, lives alongside
   `commonly_post_message` in the OpenClaw `commonly` extension.

2. Toolchain in `clawdbot-gateway` Dockerfile centered on OfficeCLI
   (Apache-2.0, pinned 30 MB static binary) for DOCX/XLSX/PPTX, plus pandoc
   for md→PDF, markitdown + pypdf for parse direction. ~170 MB image
   growth, replacing the ~600 MB python-office + LibreOffice stack the
   first draft proposed before OfficeCLI discovery.

3. Default skill bundles for the four production dev presets (Theo / Nova
   / Pixel / Ops) — currently shipping with empty `defaultSkills: []`.
   Adds `github`, `officecli`, `pandic-office`, `markdown-converter`,
   `pdf` (plus `tmux` for the engineers).

4. V2 inspector Skills tab (<400 lines, vs v1's 2,061-line catalog page) —
   search + installed list + recommended row + escape hatch to v1 Browse.

Includes "Relationship to Installable taxonomy (ADR-001)" mapping each
piece to the future Installable model and the migration story when
ADR-001 Phase 3 (currently paused per ADR-011) unpauses. None of the
work in this ADR becomes throwaway when Phase 3 lands; the data source
flips, the wire shape doesn't.

Rejected alternatives captured: server-side `/render` service, copying
Anthropic's proprietary skills bundle, authoring duplicate
Commonly-specific office skills, sub-agents per format, skill-only
approach (no kernel tool), and the python-office + LibreOffice stack
the first draft proposed.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v4 — expand Part 4 to cover full v2 install surfaces

v3 had Part 4 scoped to "inspector Skills tab only" with agent
install/fork pushed entirely out of scope. That left the user-asked
v2 marketplace page and Agents tab undesigned.

v4 expands Part 4 into four sections:

  4a. Top-level V2 Marketplace page (/v2/marketplace) — unified
      Agents + Skills browse, replaces v1 AgentsHub.tsx (4954 lines)
      and SkillsCatalogPage.tsx (2061 lines) over time. Wires on top
      of existing /api/marketplace/* (PR #215+#230) and /api/skills/*.

  4b. Inspector Skills tab — per-pod contextual install. Shows which
      agents have which skills.

  4c. Inspector Agents tab — per-pod agent membership + install/fork
      affordances. Per-installed-agent: Talk to / Configure / Fork.
      Per-browse-agent: Install / Fork.

  4d. Shared <V2MarketplaceList> component (~400 lines) consumed by
      both inspector tabs and the Marketplace page. Future apps and
      widgets ports cleanly onto the same component.

Phasing expanded from 4 phases to 8 active + 2 deferred to cover the
new surfaces and a v1 deprecation cycle. Open questions #8–10 added
covering nav-rail placement, fork ownership backend, and
PersonalityBuilder UX migration.

This ADR now also lands the active "Marketplace frontend" track from
ADR-011 alongside the file-production work — they're the same surface.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5 — correct framing after verifying backend/frontend state

v3 and v4 made two assumptions that turned out to be wrong:

1. Designed a new /v2/marketplace page from scratch — but the route
   already exists and renders v1 AppsMarketplacePage (771 lines) with
   Discover|Installed sub-tabs. /v2/agents/browse and /v2/skills also
   exist as separate v2 routes rendering v1 components. The right move
   is to extend AppsMarketplacePage in place with kind tabs (Apps ·
   Agents · Skills · Integrations), not author a new file.

2. Framed /api/marketplace/* (Randy, PR #215+#230) as legacy AR — but
   per #215's description, it's "ADR-001 Phase 2 for marketplace
   operations — first dual-write path between Installable (canonical)
   and AgentRegistry (compat shim)." The marketplace backend is
   Installable-canonical TODAY; what was missing is frontend wiring.

v5 corrections:

- Part 4a rewritten: extend existing AppsMarketplacePage with kind
  tabs, wire each tab to the right backend (Agents → Installable,
  Skills → AR for now, Apps/Integrations unchanged). Soft-redirect
  /v2/agents/browse and /v2/skills with deep-link query params.

- Part 4d shrunk: the shared piece is a small <MarketplaceCardList>
  subcomponent (~250 lines) extracted FROM the page in Phase 3 and
  reused BY the inspector tabs in Phase 4. v4's heavyweight
  <V2MarketplaceList> was over-engineering.

- Phasing collapsed from 8 active to 5 active. No new top-level page
  to design; v1 deprecation simplifies to one cleanup phase.

- §"Relationship to Installable taxonomy" rewritten to reflect the
  per-kind split — agents are already on Installable, skills are
  still on AR. ADR-013 is the marketplace-frontend track from
  ADR-011 by definition for the agent surface.

- Open question #7 (accelerate Phase 3?) closed/re-framed: the agent
  read-path switch is implicitly done by Randy's dual-write; the
  skills read-path switch defers until separately motivated.

- Open question #8 (nav-rail placement) closed: page already mounted.

- Open question #9 (fork ownership) narrowed: Randy's
  /api/marketplace/mine likely covers it; just verify response shape.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5.1 — flag catalog index numbers as 2026-02-05 snapshot

Catalog index (docs/skills/awesome-agent-skills-index.json) has
updatedAt: 2026-02-05 — nearly 3 months stale at draft time. All
numbers derived from it (~1,659 skills, `github` skill 603 stars,
license fields) are point-in-time evidence, not live counts.

Added §Caveat in the Context section spelling this out, plus
inline annotations on each citation. Numbers fetched live via
GitHub API today (OfficeCLI 2,768 stars + v1.0.70 release date)
are explicitly timestamped 2026-05-03 and treated separately.

Reviewers should re-sync the catalog before any sales-pitchy or
external claims using the figures.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5.2 — replace invented mockup numbers with placeholders

The ASCII mockups for the marketplace page and inspector Agents tab
had invented numbers that looked authoritative:

- "Apps (12)", "Agents (78)" — kind-tab counts I made up
- "★ 4.8 · 240 installs" (Liz), "★ 4.6 · 88 installs" (Theo)
- "★ 4.5 · 175 installs" (Tarik)

Reviewers could mistake these for projections or commitments. Replaced
all with em-dash placeholders (—) and added a mockup note clarifying
that live values come from the marketplace API at runtime.

Same hygiene as v5.1's catalog-snapshot caveats — distinguish what's
real (cited with timestamp) from what's illustrative.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5.3 — restore GitHub stars, add per-agent skill drawer

v5.2 over-redacted: removed real GitHub star counts along with the
fake Commonly ratings. v5.3 re-distinguishes:

- GitHub stars (real upstream signal): render. Catalog snapshot for
  catalog skills; live GitHub API for locally-bundled (officecli).
- Commonly review-style ratings (★ 4.8): don't render. The system
  doesn't exist; introducing it needs its own ADR.
- Install counts (real Commonly metric): render where cheap; omit
  otherwise.

Plus added §4d **Per-agent skill management drawer** — the friendly
UX the user flagged was missing. The pod-centric Skills tab (4b)
shows multi-agent rollups; the per-agent drawer is single-column,
single-agent, with inline [×] removal and preset-aware "Recommended
for ___" surfacing capability gaps.

Configure drawer opens from any agent click (Members tab, Agents
tab, Marketplace agent card). Tabs inside: Persona · Heartbeat ·
Skills · Memory. <300 lines target.

Existing 4d (shared subcomponent) renumbered to 4e. Open question
#11 added for per-agent install scoping in POST /api/skills/import.
Phase 4 expanded to cover the drawer.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5.4 — address 8 PR #287 review comments

Eight inline comments + PR-level summary on PR #287. All addressed:

1. Line 155 — "fall back to python-office stack" was a lie (Part 2
   removes it). Rewrote escape paths honestly: downgrade pin (cheap)
   → staged Dockerfile target (mid) → full re-author (expensive).
   Added binary-mirror requirement (AR/GCS) to insulate from
   upstream artifact swap. Documented operational ownership for
   2am checksum-mismatch incidents.

2. Line 130 — SHA256SUMS placeholder. Confirmed unverified whether
   iOfficeAI publishes SHA256SUMS. Two paths: upstream artifact OR
   committed-constant-checksum. Resolved in Phase 0a (i).
   Open question #13 added.

3. Line 516 — Open question #11 escalated to Phase 0a (ii). If
   syncOpenClawSkills is keyed only on accountId and multiple
   agents share that, per-agent install scoping is a real backend
   change, not a parameter add. Phase 4 may split into 4a/4b.

4. Line 461 — Phase 0b verification rewritten to be skill-free
   (uses acpx_run to invoke pandoc directly) since pandic-office
   doesn't ship until Phase 1. Full skill-loop verification moves
   to end of Phase 1.

5. Line 348 — Inline [×] UX. Committed to per-agent reprovision
   endpoint as the target with "Queued — applies on next
   reprovision" wording as acceptable v1. Eliminated misleading
   "removing on next sync" copy.

6. Line 373 — Configure drawer permissions. Flipped default to
   admin-only after review feedback. Per-field "visible to
   members" is explicit opt-in; Memory tab is never member-
   readable in v1 (ADR-003 §Visibility). Added Invariant 7.

7. Line 227 — Live GitHub stars. Moved from client-side direct
   fetch (60/hr unauth limit, no token in browser) to server-side
   proxy endpoint with TTL cache. Failure mode: ★ — with tooltip.

8. Line 469 — Phase 5 deletion gate. Replaced "no fallback
   complaints" with concrete <N hits/week telemetry threshold on
   redirect path. ~5 lines added to Phase 3 scope.

Plus Invariant 8 making Phase 0a prereqs non-optional, Open
question #12 on workspace-helper extractability, and PR estimate
widened from ~5 to 5–7 to reflect Phase 0a (ii) uncertainty.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

* docs(adr): ADR-013 v5.5 — call out acpx_run deprecation + ADR-005 composition

Per CLAUDE.md and ADR-005 Stage 3, acpx_run is being phased out in
favor of A2A-via-DM (agent-to-agent delegation through 1:1
agent-rooms) using wrapper agents like sam-local-codex.

ADR-013 doesn't block on the deprecation — it makes it easier:

- commonly_attach_file is correctly placed at the kernel layer
  (CAP verb), not in any specific runtime. Wrapper agents speaking
  CAP get file-attach for free.

- Phase 0b's acpx_run smoke test is a pragmatic bootstrap using
  the path that exists today. The shape of the test re-runs
  unchanged when ADR-005 Stage 3 completes.

- Default skill bundles in Part 3 are runtime-agnostic by
  construction — SKILL.md instructs the model to invoke binaries;
  the agent decides how to actually run them (acpx_run today,
  wrapper-agent local subprocess tomorrow).

Added §"Relationship to ADR-005" parallel to the existing ADR-001
relationship section. Listed ADR-005 in the companion header. Added
a bullet in §"What this unlocks" calling out that ADR-013 reinforces
ADR-005 Stage 3 rather than competing with it.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
samxu01 added a commit that referenced this pull request May 24, 2026
…-codex

Cron tick 4:

- Nova responded 5min after the nudge but punted the fix to
  sam-local-codex via "next heartbeat" delegation rather than
  executing herself. Phase-4 finding #8 added: agents reflexively
  delegate even when (a) the spec is concrete, (b) the diff is small
  (~10 lines), (c) they have the capability (gpt-5.4-mini + GH PAT +
  repo access). Possible Commonly responses logged.
- No new branch commits (HEAD still 6839eea).
- Posted push-back to Nova asking her to (a) clarify the delegation
  routing (task ID? Codex Hub @-mention?) and (b) try executing
  directly first; delegate only with concrete reasoning if the work
  is actually outside her scope.

The delegation pattern is a real signal worth tracking for whether
our heartbeat prompts encourage "do" vs "queue for someone else"
behavior.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
samxu01 added a commit that referenced this pull request May 24, 2026
Cron tick 7 (closing):

Cody shipped 807b539 (install.ts narrowing fix + 194-line regression
test) — and the diff is better than spec, adding a safety guard that
rejects deployment-shape values even if they sneak into the
runtimeType field. Theo cleared PR #434 review in 60s. Cody
explicitly signaled the phase transition.

Phase-4 finding #9 added: "Claim-the-orphan" pattern. When Nova
claimed but didn't ship for ~30 min, Cody picked it up directly
without bickering or escalation. This composes with #8
(execute-don't-handoff) — the principle isn't just self-execute
when assigned, it's also self-execute when a peer stalled.

Memorialized in commonly-skills as feedback-claim-the-orphan-stalled
-peer-work.md and indexed in MEMORY.md.

Final PR-pipeline state:
  - PR #434 revisions: SHIPPED (Cody x2)
  - ADR-2.F (Phase 3 heartbeat): PR-DRAFTABLE (Claude design)
  - Phase 2.A/B/C/D clawdbot bundle: outlined, unclaimed
  - Phase 2.E credentials runbook: unclaimed

Stop condition met: 3 of 5 items shipped or draftable; remaining 2
are natural next-sprint scope. Cron 07263397 cancelled.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
samxu01 added a commit that referenced this pull request May 24, 2026
…t-handoff posture (#436)

When a @-mention lands in a collaborative pod (≥2 active non-utility
agent installations, not an agent-room/agent-dm 1:1 pod), prepend an
inline cue to the chat.mention payload.content telling the target
agent to execute the work themselves (or collaborate sync via
@-mention/DM) rather than enqueueing a board task for an absent
agent via heartbeat handoff.

Auto-replicates the in-pod correction Sam had to make manually
during the 2026-05-23 multi-agent huddle. Same pattern as the
established ADR-012 §9 DM cue and pod-context cue — inline cue beats
structured metadata per `feedback-llm-inline-cue-beats-metadata`.

## Reference incident

2026-05-23 huddle (docs/audits/ui-smoke-2026-05-23/
huddle-observations.md, finding #8): Nova (openclaw moltbot,
gpt-5.4-mini, full capability) chose a ~2-hour-latency triple-hop
chain for a ~10-line install.ts fix:

  human → board task → Nova claim heartbeat (≤60min) → DM
  sam-local-codex → sam-local-codex heartbeat (≤60min) → diff lands

Sam corrected the posture with one in-pod message; all 4 agents
pivoted within 2 minutes. That proved the behavior IS in-context-
correctable; this commit auto-injects the same correction.

## Gating

Cue fires when ALL of:
  - Pod has ≥2 active non-utility agent installations
    (utility helpers: commonly-bot / pod-welcomer / task-clerk /
     pod-summarizer do NOT count toward the threshold)
  - pod.type is NOT 'agent-room' or 'agent-dm' (1:1 by design)
  - Target agent is NOT a code specialist
    (codex/cloud-codex/claude-code self-execute already)
  - Event type is chat.mention (not thread.mention)

Token cost ~110 per qualifying mention. Cheap relative to the
multi-hour delegation chains it prevents.

## Composes with existing cues

  chat.mention + non-specialist + collab →
    [Pod context:] [Collaborative pod:] [Collaboration:] [Reply mechanics:]
  chat.mention + non-specialist + solo  →
    [Pod context:] [Collaboration:] [Reply mechanics:]
  chat.mention + specialist             →
    [Pod context:] [Reply mechanics:]
  thread.mention                        → (no collab cue)

## Companion artifact

docs/audits/2026-05-24-phase-3/openclaw-moltbot-workspace-audit.md
captures the related Phase 3.B finding (moltbot workspace isn't a
git worktree). Filed as GH issue #437 with the full ~75-LOC fix
shape; verification needs a full deploy-test loop so deferred to a
dedicated session.

## Tests

backend/__tests__/unit/services/agentMentionService.test.js — six
new test cases under describe('collaborative-pod cue'):

  - chat.mention + ≥2 non-utility agents + non-specialist → PRESENT
  - chat.mention + single agent → NOT present (solo pod)
  - chat.mention + specialist target → NOT present (noise for codex)
  - chat.mention + 2 agents both utility helpers → NOT present
  - chat.mention + pod.type='agent-room' → NOT present
  - thread.mention + ≥2 agents → NOT present (wrong posture)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
lilyshen0722 added a commit that referenced this pull request Aug 5, 2026
#849)

The comment on the pinned OfficeCLI block claimed "Same upstream + version as
the gateway image." Same upstream holds. Same version does not, and could not:
the gateway does not pin. openclaw's Dockerfile pulls
`releases/latest/download/${asset}` with no version and no checksum, so
"same version" was true at most on the day it was written.

Measured against both running containers rather than inferred:

  backend  (pinned)             1.0.70
  gateway  (openclaw, latest)   1.0.143    ← upstream latest, published 07-28

Seventy-three releases apart, in one system, for the same file formats — this
image renders .pptx for the preview route, the gateway extracts .docx/.pptx
for commonly_read_attachment.

Found by chasing @sprint-review's observation that the two officecli install
blocks in one deploy log differ: one pins and verifies a SHA256, the other
does not. They flagged which-image-is-which as unresolved. It resolves as
ours/theirs: `#8 [3/10]` is this file (single FROM), `#37 [stage-4 17/19]` is
openclaw's (5 FROMs, guarded by the DOC_TOOLCHAIN ARG). We hardened ours in
#306 and the hardening was never carried upstream.

Not bumping to 1.0.143. The pin is doing its job, and matching a floating
target once just restarts the drift. The real fix is pinning + checksum in
openclaw's Dockerfile, which needs a PR there plus a submodule bump and so
inherits the lineage problem. Until then the divergence is recorded as a
measured fact instead of a claim of sameness, and `officecli --version` in
each container is the check.

Comment-only; no build behaviour changes.

Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
lilyshen0722 added a commit that referenced this pull request Nov 12, 2026
…heartbeat (F370 #8)

From the gate review: probes are synchronous, and an installed harness that
stalls on --version (hermes can take 30s with its retry) would block the
daemon's loop on each short recheck. Missing harnesses are now re-probed one
at a time, and one slower than a second waits for the five-minute refresh.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01MDs9DPXBiwPK6RMAX2e277
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant